from django.db import models
from django.contrib.comments.models import BaseCommentAbstractModel

class CommentModel(BaseCommentAbstractModel):
        name = models.CharField(max_length=50)
        date_of_birth = models.DateField()
        comment = models.TextField()
        date_posted = models.DateField()
        is_public = models.BooleanField(default=True)

        def __unicode__(self):
                return '%s by %s on %s' %(self.comment[:50], self.name, self.date_posted)

        class Meta:
                ordering = ('date_posted',)
